package com.xyzwps.lib.ap;

import javax.lang.model.element.RecordComponentElement;

public record Accessor(String name, FieldInfo field,
                       MethodInfo getter, MethodInfo setter,
                       RecordComponentElement recordComponent) {

    public boolean isReadable() {
        return getter != null;
    }

    public boolean isWritable() {
        return setter != null;
    }

    public boolean isRecordComponent() {
        return recordComponent != null;
    }
}
